package demo3;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component;

@Component
public class Person {
    @Autowired
    private Sweater sweater;
    public void play() {
      //  Sweater sweater = new Sweater();
       sweater.wear();

       // Tshort tshort = new Tshort();
        //tshort.wear();
        System.out.println("出去玩");

    }
}
